package com.ctbri.manage.process.model;

/**
 * 配置对象 SQLConfig
 *
 * @author qs
 * @date 2023-04-20
 */
public class GeneratorConfig {
    private static final long serialVersionUID = 1L;

    /**
     * #模板类型 1-mysql 2-hive
     */
    private int dataType;

    /**
     * 模板编号
     */
    private String templateCode;

    /**
     * 基准表，例如：tableName1=test_a
     */
    private String tableName1;

    /**
     * 目标表，例如：tableName2=test_b
     */
    private String tableName2;

    /**
     * 基准表对应查询字段，例如：filedArr1=names,hobby
     */
    private String[] filedArr1;

    /**
     * 目标表对应查询字段 例如：filedArr2=names,hobby
     */
    private String[] filedArr2;

    /**
     * #参数:若‘北京’为参数，表示省，否则为空代表全部数据
     */
    private String province;

    /**
     * #该模板是否为省公司使用 1-集团公司；2-省公司
     */
    private  int  checkFlag;


    public GeneratorConfig(int dataType, String templateCode, String tableName1, String tableName2, String[] filedArr1, String[] filedArr2,
                           String province) {
        this.dataType = dataType;
        this.templateCode = templateCode;
        this.tableName1 = tableName1;
        this.tableName2 = tableName2;
        this.filedArr1 = filedArr1;
        this.filedArr2 = filedArr2;
        this.province = province;
    }

    public GeneratorConfig(int dataType, String templateCode, String tableName1, String tableName2, String[] filedArr1, String[] filedArr2, String province, int checkFlag) {
        this.dataType = dataType;
        this.templateCode = templateCode;
        this.tableName1 = tableName1;
        this.tableName2 = tableName2;
        this.filedArr1 = filedArr1;
        this.filedArr2 = filedArr2;
        this.province = province;
        this.checkFlag = checkFlag;
    }

    public int getDataType() {
        return dataType;
    }

    public void setDataType(int dataType) {
        this.dataType = dataType;
    }

    public String getTemplateCode() {
        return templateCode;
    }

    public void setTemplateCode(String templateCode) {
        this.templateCode = templateCode;
    }

    public String getTableName1() {
        return tableName1;
    }

    public void setTableName1(String tableName1) {
        this.tableName1 = tableName1;
    }

    public String getTableName2() {
        return tableName2;
    }

    public void setTableName2(String tableName2) {
        this.tableName2 = tableName2;
    }

    public String[] getFiledArr1() {
        return filedArr1;
    }

    public void setFiledArr1(String[] filedArr1) {
        this.filedArr1 = filedArr1;
    }

    public String[] getFiledArr2() {
        return filedArr2;
    }

    public void setFiledArr2(String[] filedArr2) {
        this.filedArr2 = filedArr2;
    }

    public String getProvince() {
        return province;
    }

    public void setProvince(String province) {
        this.province = province;
    }

    public int getCheckFlag() {
        return checkFlag;
    }

    public void setCheckFlag(int checkFlag) {
        this.checkFlag = checkFlag;
    }
}
